package com.xyoto.takeawayBusiness.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

/**
 * @Description
 * @Author: TingFeng
 * @CreateTime: 2022/5/12  16:57
 */
@Data
@ApiModel("新增外卖管理")
public class AddTakeawayDTO {
    @ApiModelProperty("店铺id")
    @NotNull
    private Integer shopId;

    @ApiModelProperty("外卖功能是否开启（1-开启，2 - 关闭 ）")
    @NotNull
    @Range(min = 1,max = 2,message = "1-开启，2 - 关闭")
    private Short takeawayStatus;

    @ApiModelProperty("自助接单（1-开启，2-关闭）")
    @NotNull
    @Range(min = 1,max = 2,message = "1-开启，2 - 关闭")
    private Short selfHelpOrder;

    @ApiModelProperty("配送费")
    @NotNull
    @Min(value = 0,message = "最小为0")
    private Integer distributionFee;

    @ApiModelProperty("送达时间")
    @NotNull
    private Long deliveryTime;

    @ApiModelProperty("自动打印小票（1-开，2-关）")
    @NotNull
    @Range(min = 1,max = 2,message = "1-开启，2 - 关闭")
    private Short autoPrintReceipt;

    @ApiModelProperty("打印机名称")
    @NotNull
    private String printerName;
}
